<%@ taglib prefix="s" uri="/struts-tags"  %>
<script type="text/javascript">



$(function() {

	$('#newUserType').validate(
			{
			submitHandler : function(form) {
				$.post('./userperson/newUserType.action', $('#newUserType').serialize(),
						function(respuestaHTML) {
							$('#formAddUser').html('<img alt="loading" src="img/ajax-loader.gif"><p>Adding new user type...<p>');
							loadNewUserForm();
						});
			}
		});
});
</script>

<s:form action="newUserType.action" id="newUserType" cssClass="well form-inline" theme="simple" >
	<s:hidden name="userType.id" />
	<label>New user type</label>
	<s:textfield name="userType.name" label = "Name" cssClass="required" />
	<s:submit cssClass="btn btn-success" value="Save" />
</s:form>
